<!DOCTYPE html>
<html  xmlns:th="http://www.thymeleaf.org">
	<head>
		<meta charset="utf-8">
		<title>大数据管理平台</title>
		<meta charset="UTF-8">
		<link href="../css/BigData.css" rel="stylesheet" type="text/css" />
		<link href="../css/index.css" rel="stylesheet" type="text/css" />
		<link href="../css/index01.css" rel="stylesheet" type="text/css" />
		<link href="../css/Security_operation.css" rel="stylesheet" type="text/css" />
		<link href="../css/bootstrap.min.css" rel="stylesheet" type="text/css" />
		<style type="text/css">
			html {
				height: 100%
			}

			body {
				height: 100%;
				margin: 0px;
				padding: 0px
			}

			#container {
				height: 500px;
				width: 800px;
				overflow: hidden;
				margin: 0;

			}
		</style>
		<script type="text/javascript" src="https://api.map.baidu.com/api?v=1.0&type=webgl&ak=0Lss7hsGkeXuCrtt2iksw2XGG3u5y9Nw">
		</script>
	</head>
	<body>
		<div class="data_bodey">
			<div class="index_nav">
				<ul style="height: 30px; margin-bottom: 0px;">
					<li class="l_left total_chose_pl  nav_active">统计分析一</li>
					<li class="l_left total_chose_pl">统计分析二</li>
					<li class="r_right total_chose_pl">统计分析三</li>
					<li class="r_right total_chose_pl">统计分析四</li>
					<li class="r_right total_chose_pl">统计分析五</li>
				</ul>
				<div class="total_chose_box">
					<div style="height: 32px;"></div>
					<span class="chose_tltle">请选择年份：</span>
					<select class="year_chose">
						<option>2017</option>
						<option>2016</option>
						<option>2015</option>
						<option>2014</option>
						<option>2013</option>
						<option>2012</option>
					</select>
					<span class="chose_tltle">请输入月份：</span>
					<input class="chose_text_in">
					<button class="chose_enter">确定</button>
				</div>
				<div class="clear"></div>
			</div>
			<div class="index_tabs">
				<div class="inner">
					<div class="data_left03">
						<div class="dataAllNo01 maginS01">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit3">在训班级整体情况分析</div>
									<table class="table_data01" id="classTb">
										<tr>
											<td>班级名称</td>
											<td>在训人数</td>
											<td>项目经理</td>
											<td>重点关注人数</td>
											<td>课程阶段</td>
										</tr>
									</table>
									<p class="data_chart01" id="zhanbi02"></p>
								</div>
							</div>
						</div>
					</div>
					<div class="data_left04">

						<!--style="margin-top: 6.3%"-->
						<div class="dataAllNo01">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit3">各班级作业情况分析</div>
									<table class="table_data02" id="classWork"></table>
									<p class="zhanleft02" id="allAly03"></p>
									<table class="table_data_ex" id="lessThanFouty">
										<caption class="font04">本周核心作业完成率低于40%学员列表</caption>
										<tr>
											<td>姓名</td>
											<td>班级</td>
											<td>核心作业完成率</td>
											<td>课程阶段</td>
											<td>完善措施</td>
										</tr>
									</table>
								</div>
							</div>
						</div>
					</div>
					<div class="data_left03">
						<div class="dataAllNo01 maginS01">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit3">各班级考核情况分析</div>			
										<table class="table_data02" id="classTb1">
										</table>
										<!--班级平均成绩图表-->
										<div id="allAly04" style="width: 90%; height: 45%;margin-top: 10px;"></div>
										<!--A/B/C/D类学员图表-->
										<div id="allAly05" style="width: 90%; height: 45%;margin-top: 10px;"></div>
									</div>
								</div>
							</div>
						</div>
					</div>
				<!-----------项目扩展功能---------------->
				<div class="inner" style="display: none">
					<div class="clear"></div>
					<div class="data_left05">
						<div class="dataAllNo02 ">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit">当周项目经理发布作业次数</div>
									<div class="maincenter" style="width: 400px; height: 400px;" id="shijian01"></div>
								</div>
							</div>

						</div>
					</div>
					<div class="data_left05">
						<div class="dataAllNo02 ">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit">学员各省就业空间展示</div>
									<div style="width: 900px; height: 370px;" id="shijian03"></div>
								</div>
							</div>

						</div>
					</div>
					<div class="clear"></div>
					<div class="data_left05">
						<div class="dataAllNo02">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit">当周各班级考核次数</div>
									<div class="maincenter" style="width: 800px; height: 400px;" id="shijian02"></div>
								</div>
							</div>
						</div>
					</div>
					<div class="data_left05">
						<div class="dataAllNo02">
							<div class="dataAllBorder01">
								<div class="dataAllBorder02">
									<div class="data_tit">学员空间定位信息</div>
									</div>
								</div>

							</div>
						</div>
					</div>
					<!-----------项目扩展功能---------------->
				</div>
			</div>
	</body>
</html>
<script src="../js/echarts.min.js"></script>
<script src="../js/jquery.js"></script>
<script src="../js/index.js"></script>
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/echarts@5.2.0/dist/echarts.min.js"></script>
<script type="text/javascript" src="https://api.map.baidu.com/api?v=2.0&ak=1AoNV2RRAyOyIpZRfHPopWNKexyMmNfn"></script>
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/echarts@5.2.0/dist/extension/bmap.min.js"></script>
<script type="text/javascript">


	//地图
	$(function () {
		// 基于准备好的dom，初始化echarts实例
		var myChart = echarts.init(document.getElementById('shijian03'));
		// 指定图表的配置项和数据
		$.ajax({
			type:"get", //向后台发送请求的方式
			url:"/manager/analysis/ExhibitionOfEmploymentSpaceInEachProvince", //向后台请求的url地址
			dataType:"json", //服务器返回的数据类型
			success:function(data){
				console.log("1111111111111"+data);
				//异步交互成功的回调函数，data就是后台返回的json数据

				var arr = [];
				//循环遍历服务器返回的数组对象
				for(var i = 0; i < data.length; i++) {
					//获取每一个数组元素
					var obj = data[i];
					//获取obj对象的属性值
					var classname = obj.address;
					var avg_score = obj.num;
					//声明对象
					var target = {};
					target.name = classname;
					target.value = avg_score;
					arr[i] = target;
				}
				const geoCoordMap = {
					上海: [121.48, 31.22],
					北京: [116.46, 39.92],
					宝鸡: [107.15, 34.38],
					开封: [114.35, 34.79],
					杭州: [120.19, 30.26],
					武汉: [114.31, 30.52],
					郑州: [113.65, 34.76],
				}


				var a=arr.sort(function (a, b) {
					return b.value - a.value;
				}).slice(0, 5)

				var res1 = [];
				for (var i = 0; i < a.length; i++) {
					var geoCoord = geoCoordMap[a[i].name];
					if (geoCoord) {
						res1.push({
							name: a[i].name,
							value: geoCoord.concat(a[i].value)
						});
					}
				}


				var res = [];
				for (var i = 0; i <arr.length; i++) {
					var geoCoord = geoCoordMap[arr[i].name];
					if (geoCoord) {
						res.push({
							name: arr[i].name,
							value: geoCoord.concat(arr[i].value)
						});
					}
				}

				console.log(res);
				console.log(res1);


				myChart.setOption({
					title: {
						text: '毕业生就业去向',
						subtext: 'data from student',
						left: 'center'
					},
					tooltip: {
						trigger: 'item'
					},
					bmap: {
						center: [104.114129, 37.550339],
						zoom: 6,
						roam: true,
						mapStyle: {
							styleJson: [{
								"featureType": "land",
								"elementType": "geometry",
								"stylers": {
									"color": "#d5daf8ff"
								}
							}, {
								"featureType": "poilabel",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "poilabel",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "water",
								"elementType": "geometry",
								"stylers": {
									"color": "#d8a499ff"
								}
							}, {
								"featureType": "water",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#7293d4ff"
								}
							}, {
								"featureType": "water",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#abc0e9ff"
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#94aee4ff"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#abc0e9ff"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#94aee4ff"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#94aee4ff"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#bcd0f5ff"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#94aee4ff"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#bcd0f5ff"
								}
							}, {
								"featureType": "arterial",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#bcd0f5ff"
								}
							}, {
								"featureType": "arterial",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#94aee4ff"
								}
							}, {
								"featureType": "railway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "subway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "highwaysign",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "highwaysign",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "nationalwaysign",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "nationalwaysign",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "provincialwaysign",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "provincialwaysign",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "tertiarywaysign",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "tertiarywaysign",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "subwaylabel",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "subwaylabel",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "tertiaryway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#f0f0f0ff"
								}
							}, {
								"featureType": "tertiaryway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#b6cbf3ff"
								}
							}, {
								"featureType": "fourlevelway",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#f0f0f0ff"
								}
							}, {
								"featureType": "fourlevelway",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#b6cbf3ff"
								}
							}, {
								"featureType": "local",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#b6cbf3ff"
								}
							}, {
								"featureType": "local",
								"elementType": "geometry.fill",
								"stylers": {
									"color": "#f0f0f0ff"
								}
							}, {
								"featureType": "green",
								"elementType": "geometry",
								"stylers": {
									"color": "#b6c1fdff"
								}
							}, {
								"featureType": "building",
								"elementType": "geometry.topfill",
								"stylers": {
									"color": "#cbd0ffff"
								}
							}, {
								"featureType": "building",
								"elementType": "geometry.sidefill",
								"stylers": {
									"color": "#cbd0ffff"
								}
							}, {
								"featureType": "building",
								"elementType": "geometry.stroke",
								"stylers": {
									"color": "#6e79b8ff"
								}
							}, {
								"featureType": "manmade",
								"elementType": "geometry",
								"stylers": {
									"color": "#cdd5fdff"
								}
							}, {
								"featureType": "manmade",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "manmade",
								"elementType": "labels.text.stroke",
								"stylers": {
									"weight": 3,
									"color": "#ffffffff"
								}
							}, {
								"featureType": "education",
								"elementType": "geometry",
								"stylers": {
									"color": "#b9c4fdff"
								}
							}, {
								"featureType": "education",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "education",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "scenicspots",
								"elementType": "geometry",
								"stylers": {
									"color": "#c7cffcff"
								}
							}, {
								"featureType": "scenicspots",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "scenicspots",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "transportation",
								"elementType": "geometry",
								"stylers": {
									"color": "#c9dcfdff"
								}
							}, {
								"featureType": "transportation",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "transportation",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "scenicspotslabel",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "scenicspotslabel",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "scenicspotslabel",
								"elementType": "labels.icon",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "country",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "country",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "city",
								"elementType": "labels.text.fill",
								"stylers": {
									"color": "#e6a0c4ff"
								}
							}, {
								"featureType": "city",
								"elementType": "labels.text.stroke",
								"stylers": {
									"color": "#ffffffff",
									"weight": 3
								}
							}, {
								"featureType": "district",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "town",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "village",
								"elementType": "labels",
								"stylers": {
									"visibility": "off"
								}
							}, {
								"featureType": "scenicspots",
								"elementType": "labels.text",
								"stylers": {
									"fontsize": 26
								}
							}, {
								"featureType": "scenicspotslabel",
								"elementType": "labels.text",
								"stylers": {
									"fontsize": 26
								}
							}, {
								"featureType": "manmade",
								"elementType": "labels.text",
								"stylers": {
									"fontsize": 26
								}
							}, {
								"featureType": "education",
								"elementType": "labels.text",
								"stylers": {
									"fontsize": 26
								}
							}, {
								"featureType": "transportation",
								"elementType": "labels.text",
								"stylers": {
									"fontsize": 26
								}
							}, {
								"featureType": "highway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "highway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "highway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "highway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "highway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "highway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "highway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "highway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "highway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "nationalway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "nationalway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "nationalway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "nationalway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "nationalway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "provincialway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "8"
								}
							}, {
								"featureType": "provincialway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "9"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "8"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "9"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "8"
								}
							}, {
								"featureType": "provincialway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "8,9",
									"level": "9"
								}
							}, {
								"featureType": "cityhighway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "cityhighway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "cityhighway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "cityhighway",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "6"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "7"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "8"
								}
							}, {
								"featureType": "cityhighway",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "6,9",
									"level": "9"
								}
							}, {
								"featureType": "arterial",
								"stylers": {
									"curZoomRegionId": "0",
									"curZoomRegion": "9,9",
									"level": "9"
								}
							}, {
								"featureType": "arterial",
								"elementType": "labels",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "9,9",
									"level": "9"
								}
							}, {
								"featureType": "arterial",
								"elementType": "geometry",
								"stylers": {
									"visibility": "off",
									"curZoomRegionId": "0",
									"curZoomRegion": "9,9",
									"level": "9"
								}
							}]
						}
					},
					series: [
						{
							name: '就业人数',
							type: 'scatter',
							coordinateSystem: 'bmap',
							data: res,
							symbolSize: function (val) {
								return val[2] /2;
							},
							encode: {
								value: 2
							},
							label: {
								formatter: '{b}',
								position: 'right',
								show: false
							},
							itemStyle:{
								color:'#5cb3ff',
							},
							emphasis: {
								label: {
									show: true
								}
							}

						},
						{
							name: 'Top 5',
							type: 'effectScatter',
							coordinateSystem: 'bmap',
							data:res1,
							symbolSize: function (val) {
								return val[2] / 2;
							},
							encode: {
								value: 2
							},
							showEffectOn: 'render',
							rippleEffect: {
								brushType: 'stroke'
							},
							label: {
								formatter: '{b}',
								position: 'right',
								show: true
							},
							itemStyle: {
								color:'#ff50b3',
								shadowBlur: 10,
								shadowColor: '#fff80b'
							},
							emphasis: {
								scale: true
							},
							zlevel: 1
						}
					]
				});
			},

		});


	});




	$(function(){

		var myChart = echarts.init($("#zhanbi02")[0]);
		// 指定图表的配置项和数据
		// 指定图表的配置项和数据
		var option = {
			grid:{
				top:'35%',//距上边距

				left:'10%',//距离左边距

				right:'10%',//距离右边距

				bottom:'1%',//距离下边距

			},
			title: {
				text: '各班的在训人数和关注人数',
				left: 'center',
				textStyle:{
					color: "white",
					fontWeight: "bold",
				}

			},

			tooltip: {
				trigger: 'axis'
			},

			xAxis: [{
				type: 'category',
				boundaryGap: false,
				data: []
			}],
			yAxis: {
				type: 'value',
				axisLabel: {
					formatter: '{value} 人'
				}
			},
			series: [
				{
					top: 1160,
					bottom: 60,
					name: '总人数',
					type: 'line',
					data: [],
					markPoint: {
						data: [
							{ type: 'max', name: 'Max' },
							{ type: 'min', name: 'Min' }
						]
					},
					markLine: {
						data: [{ type: 'average', name: 'Avg' }]
					}
				},
				{
					name: '关注人数',
					type: 'line',
					data:[],

					markLine: {
						data: [
							{ type: 'average', name: 'Avg' }
						]
					}
				}
			]
		};
		myChart.setOption(option);
		//--------------班级整体信息可视化start----------------
		//发送异步请求
		//班级整体情况




		$.ajax({
			url:"/manager/analysis/listClssesInfo",
			type:"get",
			dataType:"json",
			success:function (data) {

//局部刷新表格数据
				console.log(data);
				//班级总人数
				var arr1 = [];
				//班级关注人数
				var arr2 = [];
				//班级名称
				var arr3 = [];


				if(data != null){
					$.each(data,function (index,item) {

						arr1[index] = item.f_remainum;
						arr2[index] = (item.num == undefined ? 0 : item.num);
						arr3[index] = item.f_classname;

						$("#classTb").append("<tr>" +
								"<td>"+item.f_classname+"</td>" +
								"<td>"+item.f_remainum+"</td>" +
								"<td>"+item.f_mastername+"</td>" +
								"<td>"+(item.num == undefined ? 0 : item.num)+"</td>" +
								"<td>"+item.f_progress+"</td>" +
								"</tr>");
					});
				}
				//初始化折线图的数据
				console.log(arr1);
				console.log("------------------");
				console.log(arr2);
				console.log(arr3);
				//设置图标的属性分别对应以上三个数组即可
				myChart.setOption({

					series: [
						{
							data: arr1,
						},
						{
							data:arr2,
						},
						{
							data:arr3,
						}
					]
				});
			}
		});
	});
	//发送异步请求，获取班级信息列表

	//核心作业提交率和完成率统计图标展示
	$(function() {
		var myChart = echarts.init($("#allAly03")[0]);
		$.ajax({
			url:"/manager/analysis/coreRateSubmit",
			type:"get",
			dataType:"json",
			success:function (data) {
				console.log(data);
				const arr1 = [];
				const arr2 = [];
				const arr3 = [];
				for (let o of data) {
					arr1.push(o.f_classname);
					arr2.push(o.avg_core);
					arr3.push(o.submit_rate);
				}
				myChart.setOption(
						{
							title: {
								text: '本周核心作业提交率和完成率统计',
								textStyle: {
									color: "#e9ebee"

								},
								x: 'center'

							},
							tooltip: {
								trigger: "axis",
								axisPointer: {
									type: "shadow"
								},
								formatter:'{b}<br />{a0}: {c0}%<br />{a1}: {c1}%'

							},
							legend: {
								orient: 'vertical',
								x: 'left',
								data:['提交率',"完成率"],
								textStyle: {
									color: "#e9ebee"

								},
							},
							calculable: false,
							xAxis: [{
								type: 'category',
								splitLine: {
									show: false
								},
								axisLabel: {
									formatter: '{value} ',
									textStyle: {
										color: '#a4a7ab',
										align: 'right'
									}
								},
								data: arr1
							}],
							yAxis: [{
								type: 'value',
								splitLine: {
									show: false
								},
								axisLabel: {
									interval: 'auto',
									formatter: '{value} %',
									textStyle: {
										color: '#a4a7ab',
										align: 'right'
									}
								}
							}],
							grid: {
								borderWidth: 0
							},
							series: [{
								name: '完成率',
								type: 'bar',
								data: arr2,
								itemStyle: {
									normal: {
										color: '#2481ff'
									}
								},
								markPoint: {
									data: [{
										type: 'max',
										name: '最大值'
									},
										{
											type: 'min',
											name: '最小值'
										}
									]
								},
								markLine: {
									data: [{
										type: 'average',
										name: '平均值'
									}]
								}
							},
								{
									name: '提交率',
									type: 'bar',
									data: arr3,
									itemStyle: {
										normal: {
											color: '#1afffd'
										}
									},
									markPoint: {
										data: [{
											type: 'max',
											name: '最大值'
										},
											{
												type: 'min',
												name: '最小值'
											}
										]
									},
									markLine: {
										data: [{
											type: 'average',
											name: '平均值'
										}]
									}
								}
							]
						}
				)

			},
			error:function(){
				alert("异步交互失败~");
			}
		});
	});
	//发送异步请求，获取本周核心作业完成率低于40%学员列表
	$(function(){
		$.ajax({
			url:"/manager/analysis/listStudentCoreTaskCompleteRateLessForty",
			type:"get",
			dataType:"json",
			success:function (data) {
				//局部刷新表格数据
				console.log("数据："+data);
				if(data != null){
					for (var i=0;i<data.length;i++){
					$("#lessThanFouty").append("<tr>" +
							"<td>"+data[i].f_name+"</td>" +
							"<td>"+data[i].f_classname+"</td>" +
							"<td>"+(data[i].f_core == undefined ? 0 : data[i].f_core)+"</td>" +
							"<td>"+data[i].f_progress+"</td>" +
							"<td>"+(data[i].f_suggestion ==undefined ? "无": data[i].f_suggestion)+"</td>" +
							"</tr>");
					}
					// $.each(data,function (index,item) {
					// 	console.log(item);
					//
					// 	$("#lessThanFouty").append("<tr>" +
					// 			"<td>"+item.f_name+"</td>" +
					// 			"<td>"+item.f_classname+"</td>" +
					// 			"<td>"+(item.f_core == undefined ? 0 : item.f_core)+"</td>" +
					// 			"<td>"+item.f_progress+"</td>" +
					// 			"<td>"+item.f_suggestion+"</td>" +
					// 			"</tr>");
					// });
				}
			}
		});
	});
	//发送异步请求，获取本周总成绩、本周平均成绩
	$(function(){
		$.ajax({
			url:"/manager/analysis/findExercisingTotalClassesTotalGradeAndAvgGrade",
			type:"get",
			dataType:"json",
			success:function (data) {
				//局部刷新表格数据
				console.log(data);
				if(data != null){
					$("#classTb1").append("<tr>" +
							"<td>"+"本周总成绩"+"</td>" +
							"<td>"+data.score_sum+"</td>" +
							"<td>"+"本周平均成绩"+"</td>" +
							"<td>"+data.score_avg+"</td>" +
							"</tr>");
				}
			}
		});
	});

	//核心上面那四个数据
	$(function(){
		$.ajax({
			url:"/manager/analysis/classHomeworkAnalysis",
			type:"get",
			dataType:"json",
			success:function (data) {
				//局部刷新表格数据
				console.log(data);
				if(data != null){
					console.log(data.finishRate);
					console.log(data.submit_rate);
					console.log(data.lt40_rate);
					console.log(data.rt80_rate);
					$("#classWork").append("<tr>" +
							"<td class=\"font07\">"+"完成率"+"</td>" +
							"<td class=\"font03\">"+data.finishRate+"%"+"</td>" +
							"<td class=\"font07\">"+"提交率"+"</td>" +
							"<td class=\"font02\">"+data.submit_rate+"%"+"</td>" +
							"</tr>"+"<tr>" +
							"<td class=\"font07\">"+"完成率低于40%占比"+"</td>" +
							"<td class=\"font01\">"+data.lt40_rate+"%"+"</td>" +
							"<td class=\"font07\">"+"完成率高于80%占比"+"</td>" +
							"<td class=\"font01\">"+data.rt80_rate+"%"+"</td>" +
							"</tr>"
					);
				}
			}
		});
	});

	$(function(){
		var myChart = echarts.init(document.getElementById('allAly04'));
		console.log(myChart)
		option = {
		    title: {
		        text: '本周各班级平均成绩',
		        left: 'center',
				textStyle:{
					color: "white",
					fontWeight: "bold",					
				}
		    },
		    tooltip: {
		        trigger: 'item',
				formatter: "{a} <br/>{b} : {c}%"
		    },
		    series: [
		        {
		            name: '平均成绩',
		            type: 'pie',
		            radius: '50%',
		            data: [
		                {value: 80, name: 'java297'},
		                {value: 75, name: 'java230'},
		                {value: 35.4, name: '大数据'},
		                {value: 86, name: 'java299'},
		                {value: 90, name: 'java289'}
		            ],
		            emphasis: {
		                itemStyle: {
		                    shadowBlur: 10,
		                    shadowOffsetX: 0,
		                    shadowColor: 'rgba(0, 0, 0, 0.5)'
		                }
		            }
		        }
		    ]
		};	
		myChart.setOption(option);
		$.ajax({
			url:"/manager/analysis/findExercisingClassAvgGrade",
			type:"get",
			dataType:"json",
			success:function (data) {
				console.log(data);
				var arr=[];
				for (var i=0;i<data.length;i++){
					var tar={};
					var classname=data[i].f_classname;
					var score=data[i].score_avg
					tar.name=classname;
					tar.value=score;
					arr[i]=tar;
				}
				myChart.setOption({
					series: [{
						data: arr
					}]
				});
			},
			error:function(){
				alert("异步交互失败~");
			}
		});
	});
	//A/B/C/D类学员图表
	$(function () {
		var myChart3 = echarts.init(document.getElementById('allAly05'));
		console.log(myChart3);
		option = {

			title: {
				text: '当周学员成绩分类',
				left: 'center',
				textStyle:{
					color: "white",
					fontWeight: "bold",
				}
			},
			tooltip: {
				trigger: 'item',
				formatter: "{a} <br/>{b} : {c}%"
			},
			toolbox: {
				feature: {
					dataView: {readOnly: false},
					restore: {},
					saveAsImage: {}
				}
			},
			legend: {
				data: ['展现','点击','访问','咨询','订单']
			},

			series: [
				{
					name:'漏斗图',
					type:'funnel',
					left: '10%',
					top: 60,
					//x2: 80,
					bottom: 60,
					width: '80%',
					// height: {totalHeight} - y - y2,
					min: 0,
					max: 100,
					minSize: '0%',
					maxSize: '100%',
					sort: 'descending',
					gap: 2,
					label: {
						show: true,
						position: 'inside'
					},
					labelLine: {
						length: 10,
						lineStyle: {
							width: 1,
							type: 'solid'
						}
					},
					itemStyle: {
						borderColor: '#fff',
						borderWidth: 1
					},
					emphasis: {
						label: {
							fontSize: 20
						}
					},
					data: [
						{value: 60, name: '访问'},
						{value: 40, name: '咨询'},
						{value: 20, name: '订单'},
						{value: 80, name: '点击'},
						{value: 100, name: '展现'}
					]
				}
			]
		};
		myChart3.setOption(option);
		$.ajax({
			url:"/manager/analysis/currentWeekStudentGradeClassify",
			type:"get",
			dataType:"json",
			success:function (data) {
				console.log(data);
				var arr=[];
				var tar={};
				var grade1='A';
				var num1=data.A;
				tar.name=grade1;
				tar.value=num1;
				arr[0]=tar;
				var tar2={};
				var grade2='B';
				var num2=data.B;
				tar2.name=grade2;
				tar2.value=num2;
				arr[1]=tar2;
				var tar5={};
				var grade5='E';
				var num5=data.E;
				tar5.name=grade5;
				tar5.value=num5;
				arr[4]=tar5;
				var tar3={};
				var grade3='C';
				var num3=data.C;
				tar3.name=grade3;
				tar3.value=num3;
				arr[2]=tar3;
				var tar4={};
				var grade4='D';
				var num4=data.D;
				tar4.name=grade4;
				tar4.value=num4;
				arr[3]=tar4;

				myChart3.setOption({
					series: [{
						data: arr
					}]
				});
			},
			error:function(){
				alert("异步交互失败~");
			}
		});
	})

	//----------------拓展功能可视化静态设置----------------------
	//当周各班级考核次数
	$(function() {
		var myChart = echarts.init($("#shijian02")[0]);
		$.ajax({
			url:"/manager/analysis/NumberOfProjectManagerEvaluations",
			type:"get",
			dataType:"json",
			success:function (data) {
				console.log("11:"+data);
				const arr1 = [];
				const arr2 = [];
				const arr3 = [];
				for (let o of data) {
					arr1.push(o.f_assessor);
					arr2.push("1");
					arr3.push(o.num);
				}
				myChart.setOption(
						{
							title: {
								text: '当周各班级考核次数',
								textStyle: {
									color: "#e9ebee"

								},
								x: 'center'

							},
							tooltip: {
								trigger: "axis",
								axisPointer: {
									type: "shadow"
								}
							},
							legend: {
								orient: 'vertical',
								x: 'left',
								data:['规定考核次数',"实绩考核次数"],
								textStyle: {
									color: "#e9ebee"

								},
							},
							calculable: false,
							xAxis: [{
								type: 'category',
								splitLine: {
									show: false
								},
								axisLabel: {
									formatter: '{value} ',
									textStyle: {
										color: '#a4a7ab',
										align: 'right'
									}
								},
								data: arr1
							}],
							yAxis: [{
								type: 'value',
								splitLine: {
									show: false
								},
								axisLabel: {
									interval: 'auto',
									formatter: '{value} %',
									textStyle: {
										color: '#a4a7ab',
										align: 'right'
									}
								}
							}],
							grid: {

								borderWidth: 0,
								left:10,//距离左边距

								right:100//距离右边距

							},
							series: [{
								name: '规定考核次数',
								type: 'bar',
								data: arr2,
								itemStyle: {
									normal: {
										color: '#2481ff'
									}
								},
								markPoint: {
									data: [{
										type: 'max',
										name: '最大值'
									},
										{
											type: 'min',
											name: '最小值'
										}
									]
								},
								markLine: {
									data: [{
										type: 'average',
										name: '平均值'
									}]
								}
							},
								{
									name: '实绩考核次数',
									type: 'bar',
									data: arr3,
									itemStyle: {
										normal: {
											color: '#1afffd'
										}
									},
									markPoint: {
										data: [{
											type: 'max',
											name: '最大值'
										},
											{
												type: 'min',
												name: '最小值'
											}
										]
									},
									markLine: {
										data: [{
											type: 'average',
											name: '平均值'
										}]
									}
								}
							]
						}
				)

			},
			error:function(){
				alert("异步交互失败~");
			}
		});
	});

	$(function () {
		// 基于准备好的dom，初始化echarts实例
		var myChart = echarts.init(document.getElementById('shijian01'));
		// var option = {
		// 	title: {
		// 		text: '当周项目经理发布作业次数'
		// 	},
		// 	legend: {
		// 		data: ['预计发布作业次数', '实际作业发布次数']
		// 	},
		// 	radar: {
		// 		// shape: 'circle',
		// 		indicator: [
		// 			{ name: 'zs', max: 6},
		// 			{ name: 'ls', max: 6},
		// 			{ name: 'ww', max: 6},
		// 			{ name: 'zl', max: 6},
		// 			{ name: 'xx', max: 6},
		// 			{ name: 'yy', max: 6}
		// 		]
		// 	},
		// 	series: [
		// 		{
		// 			name: '发布作业次数',
		// 			type: 'radar',
		// 			data: [
		// 				{
		// 					value: [5, 5, 5, 5, 5, 5],
		// 					name: '预计发布作业次数'
		// 				},
		// 				{
		// 					value: [1, 2, 4, 5, 6, 2],
		// 					name: '实际作业发布次数'
		// 				}
		// 			]
		// 		}
		// 	]
		// };
		// 使用刚指定的配置项和数据显示图表。
		// myChart.setOption(option);
		$.ajax({
			url:"/manager/analysis/weekWorkNum",
			type:"get",
			dataType:"json",
			success:function (data) {
				console.log(data);
				const arr1 = [];
				const arr2 = [];
				for (let o of data) {
					arr1.push(o.f_master);
					arr2.push(o.num);
				}
				myChart.setOption(
						{
							grid:{
								top:'25%',//距上边距

								left:'35%',//距离左边距

								right:'25%',//距离右边距

								bottom:'25%',//距离下边距

							},

							legend: {
								data: ['预计发布作业次数', '实际作业发布次数']
							},
							radar: {
								// shape: 'circle',
								indicator: [
									{ name: '崔倩倩', max: 6},
									{ name: '张益博', max: 6},
									{ name: '李宇', max: 6},
									{ name: '李红', max: 6},
									{ name: '栾小梅', max: 6},
								]

							},
							series: [
								{
									name: '发布作业次数',
									type: 'radar',
									data: [
										{
											value: [5, 5, 5, 5, 5],
											name: '预计发布作业次数'
										},
										{
											value: arr2,
											name: '实际作业发布次数'
										}
									]
								}
							]
						}
				)

			},
			error:function(){
				alert("异步交互失败~");
			}
		});
	})

</script>
